﻿<?xml version="1.0" encoding="utf-8" ?>
<!--
Majesty of Omega - The next evolution of macro management space strategy

Copyright 2007 André Claaßen

This file is protected by the terms and conditions of the
Microsoft Community License (Ms-CL 1.1), a copy of which should
have been distributed along with this software. If not,
you may find the license information at the following URL:

http://www.microsoft.com/resources/sharedsource/licensingbasics/communitylicense.mspx
-->
<ResourceDictionary
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:Majesty_of_Omega_ValueConverters="clr-namespace:Majesty_of_Omega.GUI.ValueConverters;assembly="
	xmlns:Majesty_of_Omega_Config="clr-namespace:Majesty_of_Omega.Config;assembly=Majesty_of_Omega_BL"
    xmlns:Majesty_of_Omega_BL_Game="clr-namespace:Majesty_of_Omega.Model.Game;assembly=Majesty_of_Omega_BL"
    xmlns:Generator="clr-namespace:Majesty_of_Omega.Logic.Generator;assembly=Majesty_of_Omega_BL"
    xmlns:GameConfiguration="clr-namespace:Majesty_of_Omega.Logic.GameConfiguration;assembly=Majesty_of_Omega_BL"
    xmlns:Controls="clr-namespace:Majesty_of_Omega.GUI.Controls"
  xmlns:d="http://schemas.microsoft.com/expression/blend/2008" xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" mc:Ignorable="d"
  >

    <!-- O B J E C T - D A T A S O U R C E S     R E S O U R C E S .............................. -->
    <Majesty_of_Omega_BL_Game:SaveGame x:Key="MooGame" DemoGameConfiguration="2 - Arms Galaxy" />
    <ObjectDataProvider x:Key="SpreadSheetManagerDS" ObjectType="{x:Type Majesty_of_Omega_Config:SpreadSheetManager}"/>
    <GameConfiguration:SaveGameManager x:Key="GameManagerDS" />
    <Generator:TestDataGenerator x:Key="TestDataGeneratorDS" />

    <!-- V A L U E - C O N V E R T ER     R E S O U R C E S ..................................... -->
    <Majesty_of_Omega_ValueConverters:UriToImageConverter x:Key="UriToImageConverter"/>
    <BooleanToVisibilityConverter x:Key="BooleanToVisibilityConverter"/>
    <Majesty_of_Omega_ValueConverters:FormattingStringConverter x:Key="FormattingStringConverter"/>

    <!-- B I T M A P      R E S O U R C E S ..................................................... -->
    <BitmapImage x:Key="StarCursorBitmap" UriSource="pack://application:,,,/Graphics/UI/target_lg_galaxy.png" />
    <BitmapImage x:Key="LeaderSample" UriSource="pack://application:,,,/Graphics/Personal/ElaLeader02_LRG.png" />

    <!-- C O L O R        R E S O U R C E S ..................................................... -->
    <Color x:Key="TitleDeepBlueColor">#FF121249</Color>
    <Color x:Key="PanelBackgroundColor">#FF617FC1</Color>
    <Color x:Key="PanelButtonBackgroundColor">#FF485F93</Color>
    <Color x:Key="Moo3Color">#FF94A1BE</Color>
    <Color x:Key="FieldOfResearchColor">#FF84A9F9</Color>
    <Color x:Key="TechInfoColor">#FFAEC8FF</Color>

    <!-- B R U S H        R E S O U R C E S ..................................................... -->
    <LinearGradientBrush x:Key="{x:Static SystemColors.HighlightBrushKey}" EndPoint="1,0.5" StartPoint="0,0.5">
        <GradientStop Color="#FF9EA6D4" Offset="0"/>
        <GradientStop Color="#FF0B1D94" Offset="1"/>
    </LinearGradientBrush>

    <LinearGradientBrush x:Key="{x:Static SystemColors.ControlBrushKey}" EndPoint="1,0.5" StartPoint="0,0.5">
        <GradientStop Color="#FF9EA6D4" Offset="0"/>
        <GradientStop Color="#FF0B1D94" Offset="1"/>
    </LinearGradientBrush>

    <!-- Standard background for planet screens -->
    <LinearGradientBrush x:Key="PlanetStdBackground" StartPoint="0,0" EndPoint="0,1">
        <GradientStop Color="Black" Offset="0"/>
        <GradientStop Color="DarkBlue" Offset="1"/>
    </LinearGradientBrush>

    <!-- Gradient blue color for title bars -->
    <LinearGradientBrush x:Key="InfoTitleBackgroundBrush" EndPoint="1,0.5" StartPoint="0,0.5">
        <GradientStop Color="#FF5254BC" Offset="0"/>
        <GradientStop Color="#FF5254BC" Offset="1"/>
        <GradientStop Color="{StaticResource TitleDeepBlueColor}" Offset="0.541"/>
    </LinearGradientBrush>

    <LinearGradientBrush x:Key="SubTitelBrush" EndPoint="1,0.5" StartPoint="0,0.5">
        <GradientStop Color="{StaticResource TitleDeepBlueColor}" Offset="0"/>
        <GradientStop Color="#FF617FC1" Offset="1"/>
        <GradientStop Color="#FF33407B" Offset="0.221"/>
    </LinearGradientBrush>

    <!-- Title text color (White) -->
    <SolidColorBrush x:Key="TitelTextColor" Color="White"/>
    <SolidColorBrush x:Key="PanelBackgroundBrush" Color="{DynamicResource PanelBackgroundColor}"/>
    <SolidColorBrush x:Key="PanelButtonBackgroundBrush" Color="{DynamicResource PanelButtonBackgroundColor}"/>
    <SolidColorBrush x:Key="InfoPanelBorderBrush" Color="#FFF9F9F9"/>

    <!-- PATH       S T Y L E    R E S O U R C E S .............................................  -->

    <Style x:Key="DividerPathStyle" TargetType="{x:Type Path}">
        <Setter Property="Fill" Value="#FFFFFFFF" />
        <Setter Property="Stretch" Value="Fill" />
        <Setter Property="Stroke" Value="#FF444444" />
        <Setter Property="StrokeThickness" Value="1"/>
        <Setter Property="Data" Value="M24,128 L96,128"/>
    </Style>

    <!-- TextBlock  S T Y L E    R E S O U R C E S .............................................  -->

    <Style x:Key="SubWindowTitleStyle" TargetType="{x:Type TextBlock}">
        <Setter Property="TextWrapping" Value="NoWrap"/>
        <Setter Property="TextTrimming" Value="None"/>
        <Setter Property="FontWeight" Value="Bold" />
        <Setter Property="HorizontalAlignment" Value="Center" />
        <Setter Property="Foreground" Value="White" />
        <Setter Property="FontSize" Value="34" />
        <Setter Property="FontStretch" Value="Expanded" />
        <Setter Property="VerticalAlignment" Value="Top" />
        <Setter Property="Margin" Value="37.872,8,0,0" />
        <Setter Property="HorizontalAlignment" Value="Left" />
    </Style>

    <Style x:Key="StandardTextStyle" TargetType="{x:Type TextBlock}">
        <Setter Property="TextWrapping" Value="Wrap" />
        <Setter Property="HorizontalAlignment" Value="Left" />
        <Setter Property="Background" Value="{x:Null}" />
        <Setter Property="FontFamily" Value="Tahoma"/>
        <Setter Property="FontSize" Value="11"/>
        <Setter Property="Foreground" Value="#FF121212"/>
    </Style>

    <!-- Info Text Formatting -->
    <Style x:Key="InfoLabelStyle" TargetType="{x:Type TextBlock}"
         BasedOn="{StaticResource StandardTextStyle}">
        <Setter Property="FontWeight" Value="Bold"/>
    </Style>

    <Style x:Key="InfoValueStyle" TargetType="{x:Type TextBlock}"
         BasedOn="{StaticResource StandardTextStyle}">
        <Setter Property="HorizontalAlignment" Value="Right" />
    </Style>

    <Style x:Key="TitleTextStyle" TargetType="{x:Type TextBlock}">
        <Setter Property="TextWrapping" Value="Wrap" />
        <Setter Property="HorizontalAlignment" Value="Stretch" />
        <Setter Property="VerticalAlignment" Value="Center"/>
        <Setter Property="Background" Value="{x:Null}" />
        <Setter Property="FontFamily" Value="Tahoma"/>
        <Setter Property="FontSize" Value="12"/>
        <Setter Property="Foreground" Value="#FFFFFFFF" />
        <Setter Property="TextAlignment" Value="Center" />
        <Setter Property="FontWeight" Value="Bold" />
    </Style>

    <!-- Input Label  -->
    <Style x:Key="InputLabelStyle" TargetType="{x:Type TextBlock}"
         BasedOn="{StaticResource StandardTextStyle}"/>

    <!-- Title bar in panels -->
    <Style x:Key="PanelTitleStyle" TargetType="{x:Type TextBlock}"
         BasedOn="{StaticResource TitleTextStyle}" >
        <Setter Property="Background" Value="{StaticResource InfoTitleBackgroundBrush}" />
        <Setter Property="Padding" Value="0,3,0,3"/>
    </Style>

    <!-- Expander S T Y L E      R E S O U R C E S .............................................  -->
    <Style TargetType="{x:Type Expander}">
        <Setter Property="Background" Value="{DynamicResource SubTitelBrush}" />
        <Setter Property="BorderBrush" Value="{DynamicResource PanelBackgroundBrush}" />
        <Setter Property="Foreground" Value="#FFFAFAFA" />
        <Setter Property="BorderThickness" Value="0,0,0,0" />
    </Style>

    <!-- Border S T Y L E        R E S O U R C E S .............................................  -->
    <Style x:Key="PanelBorderStyle" TargetType="{x:Type Border}">
        <Setter Property="BorderBrush" Value="#FFFFFFFF" />
        <Setter Property="Padding" Value="3,3,3,3" />
        <Setter Property="CornerRadius" Value="5,5,0,0" />
        <Setter Property="VerticalAlignment" Value="Top" />
        <Setter Property="BorderThickness" Value="2,2,2,2" />
    </Style>

    <Style x:Key="SubTitleBorderStyle" TargetType="{x:Type Border}">
        <Setter Property="Padding" Value="3,3,3,3" />
        <Setter Property="Background">
            <Setter.Value>
                <LinearGradientBrush EndPoint="1,0.5" StartPoint="0,0.5">
                    <GradientStop Color="{StaticResource TitleDeepBlueColor}" Offset="0"/>
                    <GradientStop Color="#FF617FC1" Offset="1"/>
                    <GradientStop Color="#FF33407B" Offset="0.221"/>
                </LinearGradientBrush>
            </Setter.Value>
        </Setter>
    </Style>

    <Style x:Key="LightSubTitleBorderStyle" TargetType="{x:Type Border}">
        <Setter Property="Background">
            <Setter.Value>
                <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                    <GradientStop Color="#FFFFFFFF" Offset="0"/>
                    <GradientStop Color="#FFFFFFFF" Offset="1"/>
                    <GradientStop Color="#FF899BFB" Offset="0.521"/>
                </LinearGradientBrush>
            </Setter.Value>
        </Setter>
    </Style>

    <!-- GridViewColumnHeader    R E S O U R C E S .............................................  -->
    <Style x:Key="ListViewHeaderStyle" TargetType="{x:Type GridViewColumnHeader}">
        <Setter Property="Background">
            <Setter.Value>
                <LinearGradientBrush StartPoint="0.5, 0" EndPoint="0.5,1" >
                    <GradientStop Color="#FFA4B0BB" Offset="0"/>
                    <GradientStop Color="#FF62697B" Offset="0.996"/>
                    <GradientStop Color="{DynamicResource PanelBackgroundColor}" Offset="0.508"/>
                </LinearGradientBrush>
            </Setter.Value>
        </Setter>
        <Setter Property="BorderThickness" Value="0,0,0,0"/>
        <Setter Property="Margin" Value="0,0,0,-5"/>
        <Setter Property="Padding" Value="0,2,0,7"/>
        <Setter Property="Foreground" Value="#FFFFFFFF"/>
        <Setter Property="FontWeight" Value="Normal"/>
    </Style>
    <LinearGradientBrush x:Key="ListViewSelectedBrush" EndPoint="0.5,1" StartPoint="0.5,0">
        <GradientStop Color="#FFA9CDF9" Offset="0.97"/>
        <GradientStop Color="{DynamicResource FieldOfResearchColor}" Offset="0.5"/>
        <GradientStop Color="{DynamicResource FieldOfResearchColor}" Offset="0.51"/>
    </LinearGradientBrush>

    <LinearGradientBrush x:Key="ListViewMouseOverBrush" EndPoint="0.5,1" StartPoint="0.5,0">
        <GradientStop Color="#FFFFC704" Offset="0.986"/>
        <GradientStop Color="#FFF4E057" Offset="0.5"/>
        <GradientStop Color="#FFF4E057" Offset="0.51"/>
    </LinearGradientBrush>
    <Style x:Key="MooListViewStyle" TargetType="{x:Type ListView}">
        <Setter Property="ItemContainerStyle">
            <Setter.Value>
                <Style TargetType="{x:Type ListViewItem}"  >
                    <Setter Property="Background" Value="#FF84A9F9" />
                    <Style.Triggers>
                        <Trigger Property="IsSelected" Value="true">
                            <Setter Property="Background" Value="{StaticResource ListViewSelectedBrush}" />
                        </Trigger>
                        <Trigger Property="IsMouseOver" Value="true">
                            <Setter Property="Foreground" Value="DarkBlue" />
                            <Setter Property="Background" Value="{StaticResource ListViewMouseOverBrush}" />
                        </Trigger>
                    </Style.Triggers>
                </Style>
            </Setter.Value>
        </Setter>

        <Setter Property="Background">
            <Setter.Value>
                <SolidColorBrush Color="{DynamicResource FieldOfResearchColor}"/>
            </Setter.Value>
        </Setter>

    </Style>

    <!-- Page - Style            R E S O U R C E S .............................................  -->

    <Style x:Key="PageSetupStyle" TargetType="{x:Type Page}">
        <Setter Property="MinWidth" Value="1024" />
        <Setter Property="MinHeight" Value="600" />
        <Setter Property="Background" Value="{StaticResource PlanetStdBackground}" />
        <Style.Triggers>
            <EventTrigger RoutedEvent="FrameworkElement.Loaded">
                <BeginStoryboard>
                    <Storyboard>
                        <DoubleAnimation  From="0.5" To="1" Duration="0:0:1"
                              Storyboard.TargetName="{x:Null}"
                              Storyboard.TargetProperty="(UIElement.Opacity)" />
                    </Storyboard>
                </BeginStoryboard>
            </EventTrigger>
        </Style.Triggers>
    </Style>


    <Style x:Key="GlassButtonStyle" TargetType="{x:Type Button}">
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="{x:Type Button}">
                    <ControlTemplate.Resources>
                        <Storyboard x:Key="Timeline1">
                            <DoubleAnimationUsingKeyFrames BeginTime="00:00:00" Storyboard.TargetName="glow" Storyboard.TargetProperty="(UIElement.Opacity)">
                                <SplineDoubleKeyFrame KeyTime="00:00:00.3000000" Value="1"/>
                            </DoubleAnimationUsingKeyFrames>
                        </Storyboard>
                        <Storyboard x:Key="Timeline2">
                            <DoubleAnimationUsingKeyFrames BeginTime="00:00:00" Storyboard.TargetName="glow" Storyboard.TargetProperty="(UIElement.Opacity)">
                                <SplineDoubleKeyFrame KeyTime="00:00:00.3000000" Value="0"/>
                            </DoubleAnimationUsingKeyFrames>
                        </Storyboard>
                    </ControlTemplate.Resources>
                    <Border BorderBrush="#FFFFFFFF" BorderThickness="1,1,1,1" CornerRadius="4,4,4,4">
                        <Border x:Name="border" Background="#7F000000" BorderBrush="#FF000000" BorderThickness="1,1,1,1" CornerRadius="4,4,4,4">
                            <Grid>
                                <Grid.RowDefinitions>
                                    <RowDefinition Height="0.507*"/>
                                    <RowDefinition Height="0.493*"/>
                                </Grid.RowDefinitions>
                                <Border Opacity="0" HorizontalAlignment="Stretch" x:Name="glow" Width="Auto" Grid.RowSpan="2" CornerRadius="4,4,4,4">
                                    <Border.Background>
                                        <RadialGradientBrush>
                                            <RadialGradientBrush.RelativeTransform>
                                                <TransformGroup>
                                                    <ScaleTransform ScaleX="1.702" ScaleY="2.243"/>
                                                    <SkewTransform AngleX="0" AngleY="0"/>
                                                    <RotateTransform Angle="0"/>
                                                    <TranslateTransform X="-0.368" Y="-0.152"/>
                                                </TransformGroup>
                                            </RadialGradientBrush.RelativeTransform>
                                            <GradientStop Color="#B28DBDFF" Offset="0"/>
                                            <GradientStop Color="#008DBDFF" Offset="1"/>
                                        </RadialGradientBrush>
                                    </Border.Background>
                                </Border>
                                <ContentPresenter HorizontalAlignment="Center" VerticalAlignment="Center" Width="Auto" Grid.RowSpan="2"/>
                                <Border HorizontalAlignment="Stretch" Margin="0,0,0,0" x:Name="shine" Width="Auto" CornerRadius="4,4,0,0">
                                    <Border.Background>
                                        <LinearGradientBrush EndPoint="0.494,0.889" StartPoint="0.494,0.028">
                                            <GradientStop Color="#99FFFFFF" Offset="0"/>
                                            <GradientStop Color="#33FFFFFF" Offset="1"/>
                                        </LinearGradientBrush>
                                    </Border.Background>
                                </Border>
                            </Grid>
                        </Border>
                    </Border>
                    <ControlTemplate.Triggers>
                        <Trigger Property="IsPressed" Value="True">
                            <Setter Property="Opacity" TargetName="shine" Value="0.4"/>
                            <Setter Property="Background" TargetName="border" Value="#CC000000"/>
                            <Setter Property="Visibility" TargetName="glow" Value="Hidden"/>
                        </Trigger>
                        <Trigger Property="IsMouseOver" Value="True">
                            <Trigger.EnterActions>
                                <BeginStoryboard Storyboard="{StaticResource Timeline1}"/>
                            </Trigger.EnterActions>
                            <Trigger.ExitActions>
                                <BeginStoryboard x:Name="Timeline2_BeginStoryboard" Storyboard="{StaticResource Timeline2}"/>
                            </Trigger.ExitActions>
                        </Trigger>
                    </ControlTemplate.Triggers>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
        <Setter Property="Foreground" Value="#FFFFFFFF"/>
    </Style>

    <Style x:Key="SetupGroupPanel" TargetType="{x:Type GroupBox}">
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="{x:Type GroupBox}">
                    <Border Style="{DynamicResource PanelBorderStyle}" VerticalAlignment="Stretch" >
                        <Grid x:Name="LayoutRoot">
                            <Grid.RowDefinitions>
                                <RowDefinition Height="Auto" />
                                <RowDefinition Height="*"/>
                            </Grid.RowDefinitions>
                            <Border Background="{StaticResource InfoTitleBackgroundBrush}" BorderThickness="0,0,0,2" CornerRadius="0,0,0,0" BorderBrush="#FFFFFFFF" Padding="8,4,8,4" Width="Auto" Height="Auto" DockPanel.Dock="Top" VerticalAlignment="Top" >
                                <TextBlock Style="{DynamicResource TitleTextStyle}"><InlineUIContainer>
                                		<ContentPresenter HorizontalAlignment="Center"  ContentSource="Header" />
                                	</InlineUIContainer></TextBlock>
                            </Border>
                            <Border x:Name="BorderContent" Grid.Row="1" Background="{DynamicResource PanelBackgroundBrush}" Padding="5,5,5,5">
                                <ContentPresenter 
                                    Margin="2"
                                    HorizontalAlignment="Stretch"
                                    VerticalAlignment="Stretch"
                                    RecognizesAccessKey="True"
                                    ContentSource="Content"
                                 />
                            </Border>
                        </Grid>
                    </Border>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>
    <Style x:Key="SubGroupBoxStyle" TargetType="{x:Type GroupBox}">
        <Setter Property="Template" Value="{DynamicResource SubGroupBoxTemplate}"/>
    </Style>
    <ControlTemplate x:Key="SubGroupBoxTemplate" TargetType="{x:Type GroupBox}">
        <Grid SnapsToDevicePixels="True">
            <Grid.ColumnDefinitions>
                <ColumnDefinition Width="6"/>
                <ColumnDefinition Width="Auto"/>
                <ColumnDefinition Width="*"/>
                <ColumnDefinition Width="6"/>
            </Grid.ColumnDefinitions>
            <Grid.RowDefinitions>
                <RowDefinition Height="Auto"/>
                <RowDefinition Height="Auto"/>
                <RowDefinition Height="*"/>
                <RowDefinition Height="6"/>
            </Grid.RowDefinitions>
            <Border Grid.Column="0" Grid.ColumnSpan="4" Grid.Row="1" Grid.RowSpan="3" Background="{TemplateBinding Background}" BorderBrush="#00FFFFFF" BorderThickness="{TemplateBinding BorderThickness}" CornerRadius="4,4,4,4"/>
            <Border x:Name="Header" Grid.Column="1" Grid.Row="0" Grid.RowSpan="2" Padding="3,0,3,0">
                <ContentPresenter SnapsToDevicePixels="{TemplateBinding SnapsToDevicePixels}" 
                                  TextElement.Foreground="White" Content="{TemplateBinding Header}" 
                                  ContentSource="Header" ContentTemplate="{TemplateBinding HeaderTemplate}" RecognizesAccessKey="True"/>
            </Border>
            <Border Grid.ColumnSpan="4" Grid.Row="1" Grid.RowSpan="3" BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="{TemplateBinding BorderThickness}" CornerRadius="4,4,4,4">
                <Border.OpacityMask>
                    <MultiBinding ConverterParameter="7" UpdateSourceTrigger="Default">
                        <MultiBinding.Converter>
                            <BorderGapMaskConverter/>
                        </MultiBinding.Converter>
                        <Binding Path="ActualWidth" ElementName="Header"/>
                        <Binding Path="ActualWidth" RelativeSource="{RelativeSource Self}"/>
                        <Binding Path="ActualHeight" RelativeSource="{RelativeSource Self}"/>
                    </MultiBinding>
                </Border.OpacityMask>
            </Border>
            <ContentPresenter SnapsToDevicePixels="{TemplateBinding SnapsToDevicePixels}" Margin="{TemplateBinding Padding}" Grid.Column="1" Grid.ColumnSpan="2" Grid.Row="2" Content="{TemplateBinding Content}" ContentTemplate="{TemplateBinding ContentTemplate}"/>
        </Grid>
    </ControlTemplate>

    <Style x:Key="SubPanelLook" TargetType="{x:Type Controls:SetupPanelControl}">
        <Setter Property="Background" Value="{DynamicResource PanelBackgroundBrush}" />
        <Setter Property="TitleBackground" Value="{DynamicResource InfoTitleBackgroundBrush}" />
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="{x:Type Controls:SetupPanelControl}">
                    <Grid Height="Auto">
                        <Grid.RowDefinitions>
                            <RowDefinition Height="Auto" />
                            <RowDefinition Height="*"/>
                        </Grid.RowDefinitions>
                        <Border BorderBrush="{DynamicResource PanelBackgroundBrush}" Margin="0,25,0,0" Grid.RowSpan="2" BorderThickness="4,4,4,4">
                            <Border x:Name="BorderContent" Background="{TemplateBinding Background}" Width="Auto" Height="Auto" BorderBrush="#FFFFFFFF" BorderThickness="1,1,1,1" >
                                <ContentPresenter
                        				HorizontalAlignment="Stretch"
                        				VerticalAlignment="Stretch"
                        				RecognizesAccessKey="True"
                        				ContentSource="Content"
                                 />
                            </Border>
                        </Border>
                        <StackPanel x:Name="HeaderLeft" HorizontalAlignment="Left" Orientation="Horizontal">
                            <Border Width="Auto" Height="Auto" BorderBrush="{DynamicResource PanelBackgroundBrush}" BorderThickness="4,4,0,0">
                                <Border BorderThickness="1,1,0,0" CornerRadius="0,0,0,0" BorderBrush="#FFFFFFFF" Padding="8,4,8,4" Width="Auto" Height="25" Background="#FF000000" >
                                    <ContentPresenter TextBlock.TextAlignment="Center" TextElement.Foreground="White" TextElement.FontWeight="Bold" HorizontalAlignment="Stretch"  ContentSource="Header" OpacityMask="#FF000000" />
                                </Border>
                            </Border>
                            <Canvas VerticalAlignment="Bottom" Width="25" Height="25">
                                <Path Fill="#FF000000" Stretch="Fill" Stroke="{x:Null}" Width="24.917" Height="25.695" Data="M80.23665,158.11234 L100.9635,179.41773 80.199983,179.38318 z" Canvas.Top="-0.669" Canvas.Left="0.04"/>
                                <Path Fill="#FFFFFFFF" Stretch="Fill" Stroke="#FFFFFFFF" Width="25.854" Height="25.628" Data="M548.61387,223.3739 L573.51276,248.16486" StrokeThickness="1" Canvas.Left="-0.356" Canvas.Top="-0.099" StrokeEndLineCap="Triangle" StrokeStartLineCap="Triangle"/>
                                <Path Fill="#FFFFFFFF" Stretch="Fill" Stroke="{DynamicResource PanelBackgroundBrush}" StrokeDashCap="Triangle" StrokeEndLineCap="Triangle" StrokeLineJoin="Round" StrokeStartLineCap="Triangle" StrokeThickness="4" Width="29.718" Height="29.344" Data="M-2.0963868,-5.2716059 L26.05777,22.722983" Canvas.Left="-1.293" Canvas.Top="-4.474"/>
                            </Canvas>
                        </StackPanel>
                        <StackPanel x:Name="HeaderRight" Visibility="Hidden" HorizontalAlignment="Right" Orientation="Horizontal">
                            <Canvas VerticalAlignment="Bottom" Width="25" Height="25" RenderTransformOrigin="0.5,0.5">
                            	<Canvas.RenderTransform>
                            		<TransformGroup>
                            			<ScaleTransform ScaleX="-1" ScaleY="1"/>
                            		</TransformGroup>
                            	</Canvas.RenderTransform>
                                <Path Fill="#FF000000" Stretch="Fill" Stroke="{x:Null}" Width="24.917" Height="25.695" Data="M80.23665,158.11234 L100.9635,179.41773 80.199983,179.38318 z" Canvas.Top="-0.669" Canvas.Left="0.04"/>
                                <Path Fill="#FFFFFFFF" Stretch="Fill" Stroke="#FFFFFFFF" Width="25.854" Height="25.628" Data="M548.61387,223.3739 L573.51276,248.16486" StrokeThickness="1" Canvas.Left="-0.356" Canvas.Top="-0.099" StrokeEndLineCap="Triangle" StrokeStartLineCap="Triangle"/>
                                <Path Fill="#FFFFFFFF" Stretch="Fill" Stroke="{DynamicResource PanelBackgroundBrush}" StrokeDashCap="Triangle" StrokeEndLineCap="Triangle" StrokeLineJoin="Round" StrokeStartLineCap="Triangle" StrokeThickness="4" Width="29.718" Height="29.344" Data="M-2.0963868,-5.2716059 L26.05777,22.722983" Canvas.Left="-1.293" Canvas.Top="-4.474"/>
                            </Canvas>
                            <Border Width="Auto" Height="Auto" BorderBrush="{DynamicResource PanelBackgroundBrush}" BorderThickness="0,4,4,0">
                                <Border BorderThickness="0,1,1,0" CornerRadius="0,0,0,0" BorderBrush="#FFFFFFFF" Padding="8,4,8,4" Width="Auto" Height="25" Background="#FF000000" >
                                    <ContentPresenter TextBlock.TextAlignment="Center" TextElement.Foreground="White" TextElement.FontWeight="Bold" HorizontalAlignment="Stretch"  ContentSource="Header" OpacityMask="#FF000000" />
                                </Border>
                            </Border>
                        </StackPanel>
                    </Grid>
                    <ControlTemplate.Triggers>
                        <Trigger Property="Location" Value="Top">
                            <Setter TargetName="HeaderLeft" Property="Visibility" Value="Visible" />
                            <Setter TargetName="HeaderRight" Property="Visibility" Value="Hidden" />
                        </Trigger>
                        <Trigger Property="Location" Value="Middle"/>
                        <Trigger Property="Location" Value="Bottom"/>
                        <Trigger Property="Location" Value="Left">
                            <Setter TargetName="HeaderLeft" Property="Visibility" Value="Visible" />
                            <Setter TargetName="HeaderRight" Property="Visibility" Value="Hidden" />
                        </Trigger>
                        <Trigger Property="Location" Value="Right">
                            <Setter TargetName="HeaderLeft" Property="Visibility" Value="Hidden" />
                            <Setter TargetName="HeaderRight" Property="Visibility" Value="Visible" />
                        </Trigger>
                    </ControlTemplate.Triggers>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>

    <!-- MOO 3 TabControl R E S O U R C E S .............................................  -->

    <Style x:Key="MooTabItemFocusVisual">
        <Setter Property="Control.Template">
            <Setter.Value>
                <ControlTemplate>
                    <Rectangle Stroke="Black" StrokeDashArray="1 2" StrokeThickness="1" Margin="3,3,3,1" SnapsToDevicePixels="true"/>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>
    <SolidColorBrush x:Key="MooTabBackgroundBrush" Color="#FF26407C"/>
    <LinearGradientBrush x:Key="MooTabItemHotBackground" EndPoint="0,1" StartPoint="0,0">
        <GradientStop Color="#EAF6FD" Offset="0.15"/>
        <GradientStop Color="#D9F0FC" Offset=".5"/>
        <GradientStop Color="#BEE6FD" Offset=".5"/>
        <GradientStop Color="#A7D9F5" Offset="1"/>
    </LinearGradientBrush>
    <SolidColorBrush x:Key="MooTabItemSelectedBackground" Color="{DynamicResource PanelBackgroundColor}"/>
    <SolidColorBrush x:Key="MooTabItemHotBorderBrush" Color="#3C7FB1"/>


</ResourceDictionary>
